Our invitations for the companionship of the Holy Ghost occur in many ways: through the making and keeping of covenants; by praying sincerely as individuals and families; by searching the scriptures diligently; through strengthening appropriate relationships with family members and friends; by seeking after virtuous thoughts, actions, and language; and by worshipping in our homes, in the holy temple, and at church. Conversely, casualness about or the breaking of covenants and commitments, failing to pray and study the scriptures, and inappropriate thoughts, actions, and language cause the Spirit to withdraw from or to avoid us altogether.
Elder David A. Bednar of the Quorum of the Twelve Apostles